home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2001 May / SGI IRIX Base Documentation 2001 May.iso / usr / share / catman / p_man / cat3 / perl5 / integer.z / integer
Encoding:
Text File  |  1998-10-30  |  1.1 KB  |  67 lines

  1.  
  2.  
  3.  
  4. iiiinnnntttteeeeggggeeeerrrr((((3333))))                                                          iiiinnnntttteeeeggggeeeerrrr((((3333))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      integer - Perl pragma to compute arithmetic in integer instead of double
  10.  
  11. SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
  12.          use integer;
  13.          $x = 10/3;
  14.          # $x is now 3, not 3.33333333333333333
  15.  
  16.  
  17. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  18.      This tells the compiler that it's okay to use integer operations from
  19.      here to the end of the enclosing BLOCK.  On many machines, this doesn't
  20.      matter a great deal for most computations, but on those without floating
  21.      point hardware, it can make a big difference.
  22.  
  23.      See the section on _P_r_a_g_m_a_t_i_c _M_o_d_u_l_e_s in the _p_e_r_l_m_o_d manpage.
  24.  
  25.  
  26.  
  27.  
  28.  
  29.  
  30.  
  31.  
  32.  
  33.  
  34.  
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.